const platformLayout = () => import('@/layout/platforms/app/index.vue')

const appRoutes = [
  // 平台使用
  {
    path: '/app',
    component: platformLayout,
    name: '',
    meta: { title: '小程序集', roles: ['customer'] },
    children: [
      {
        path: '/app',
        name: 'app_index',
        component: () => import('@/views/platform/app/index.vue'),
        meta: { title: '控制台' }
      },
      // {
      //   path: 'manage/:plaid',
      //   name: 'app_manage',
      //   component: () => import('@/views/platform/app/appManage/index.vue'),
      //   meta: { title: '小程序配置' }
      // },
      {
        path: 'addon',
        name: 'app_addon',
        component: () => import('@/views/platform/app/addon.vue'),
        meta: { title: '应用管理' }
      },
      {
        path: 'upload',
        name: 'app_upload',
        component: () => import('@/views/platform/app/upload/index.vue'),
        meta: { title: '上传审核' }
      },
      {
        path: 'uploadSetting',
        name: 'app_setting_upload',
        component: () => import('@/views/platform/app/uploadSetting.vue'),
        meta: { title: '上传设置' }
      },
      {
        path: 'server',
        name: 'app_server',
        component: () => import('@/views/platform/app/server.vue'),
        meta: { title: '服务端配置' }
      },
      {
        path: 'setting',
        name: 'app_setting',
        component: () => import('@/views/platform/app/setting.vue'),
        meta: { title: '系统设置' }
      }
    ]
  }
]

export default appRoutes
